package com.eshop.tools.domain;

import cn.hutool.core.bean.BeanUtil;
import cn.hutool.core.bean.copier.CopyOptions;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import java.io.Serializable;

@TableName("email_config")
public class EmailConfig implements Serializable
{
    @TableId
    private Long id;
    private String fromUser;
    private String host;
    private String pass;
    private String port;
    private String user;
    
    public void copy(final EmailConfig source) {
        BeanUtil.copyProperties((Object)source, (Object)this, CopyOptions.create().setIgnoreNullValue(true));
    }
    
    public Long getId() {
        return this.id;
    }
    
    public String getFromUser() {
        return this.fromUser;
    }
    
    public String getHost() {
        return this.host;
    }
    
    public String getPass() {
        return this.pass;
    }
    
    public String getPort() {
        return this.port;
    }
    
    public String getUser() {
        return this.user;
    }
    
    public void setId(final Long id) {
        this.id = id;
    }
    
    public void setFromUser(final String fromUser) {
        this.fromUser = fromUser;
    }
    
    public void setHost(final String host) {
        this.host = host;
    }
    
    public void setPass(final String pass) {
        this.pass = pass;
    }
    
    public void setPort(final String port) {
        this.port = port;
    }
    
    public void setUser(final String user) {
        this.user = user;
    }
    
    @Override
    public boolean equals(final Object o) {
        if (o == this) {
            return true;
        }
        if (!(o instanceof EmailConfig)) {
            return false;
        }
        final EmailConfig other = (EmailConfig)o;
        if (!other.canEqual(this)) {
            return false;
        }
        final Object this$id = this.getId();
        final Object other$id = other.getId();
        Label_0065: {
            if (this$id == null) {
                if (other$id == null) {
                    break Label_0065;
                }
            }
            else if (this$id.equals(other$id)) {
                break Label_0065;
            }
            return false;
        }
        final Object this$fromUser = this.getFromUser();
        final Object other$fromUser = other.getFromUser();
        Label_0102: {
            if (this$fromUser == null) {
                if (other$fromUser == null) {
                    break Label_0102;
                }
            }
            else if (this$fromUser.equals(other$fromUser)) {
                break Label_0102;
            }
            return false;
        }
        final Object this$host = this.getHost();
        final Object other$host = other.getHost();
        Label_0139: {
            if (this$host == null) {
                if (other$host == null) {
                    break Label_0139;
                }
            }
            else if (this$host.equals(other$host)) {
                break Label_0139;
            }
            return false;
        }
        final Object this$pass = this.getPass();
        final Object other$pass = other.getPass();
        Label_0176: {
            if (this$pass == null) {
                if (other$pass == null) {
                    break Label_0176;
                }
            }
            else if (this$pass.equals(other$pass)) {
                break Label_0176;
            }
            return false;
        }
        final Object this$port = this.getPort();
        final Object other$port = other.getPort();
        Label_0213: {
            if (this$port == null) {
                if (other$port == null) {
                    break Label_0213;
                }
            }
            else if (this$port.equals(other$port)) {
                break Label_0213;
            }
            return false;
        }
        final Object this$user = this.getUser();
        final Object other$user = other.getUser();
        if (this$user == null) {
            if (other$user == null) {
                return true;
            }
        }
        else if (this$user.equals(other$user)) {
            return true;
        }
        return false;
    }
    
    protected boolean canEqual(final Object other) {
        return other instanceof EmailConfig;
    }
    
    @Override
    public int hashCode() {
        final int PRIME = 59;
        int result = 1;
        final Object $id = this.getId();
        result = result * 59 + (($id == null) ? 43 : $id.hashCode());
        final Object $fromUser = this.getFromUser();
        result = result * 59 + (($fromUser == null) ? 43 : $fromUser.hashCode());
        final Object $host = this.getHost();
        result = result * 59 + (($host == null) ? 43 : $host.hashCode());
        final Object $pass = this.getPass();
        result = result * 59 + (($pass == null) ? 43 : $pass.hashCode());
        final Object $port = this.getPort();
        result = result * 59 + (($port == null) ? 43 : $port.hashCode());
        final Object $user = this.getUser();
        result = result * 59 + (($user == null) ? 43 : $user.hashCode());
        return result;
    }
    
    @Override
    public String toString() {
        return "EmailConfig(id=" + this.getId() + ", fromUser=" + this.getFromUser() + ", host=" + this.getHost() + ", pass=" + this.getPass() + ", port=" + this.getPort() + ", user=" + this.getUser() + ")";
    }
}
